package cn.edu.java.thread.四种实现方式;

public class RunnableDemo implements Runnable{
    @Override
    public void run() {
        System.out.println(Thread.currentThread().getName() + " : 子线程结束！");
    }

    public static void main(String[] args) {
        RunnableDemo runnableDemo = new RunnableDemo();


        new Thread(runnableDemo).start();
        new Thread(runnableDemo).start();
        System.out.println(Thread.currentThread().getName() + " : 主线程结束！");
    }
}
